Skip to content

Instantly share code, notes, and snippets.

@dhh
dhh / linux-setup.sh
Last active May 21, 2024 13:25
linux-setup.sh
# CLI
sudo apt update -y
sudo apt install -y \
git curl btop \
docker.io docker-buildx \
build-essential pkg-config autoconf bison rustc cargo clang \
libssl-dev libreadline-dev zlib1g-dev libyaml-dev libreadline-dev libncurses5-dev libffi-dev libgdbm-dev libjemalloc2 \
libvips imagemagick libmagickwand-dev mupdf mupdf-tools \
redis-tools sqlite3 libsqlite3-0 libmysqlclient-dev \
rbenv apache2-utils
@HoussemNasri
HoussemNasri / BalsamiqForever.py
Last active May 21, 2024 13:25
Extend your trial period for Balsamiq Wireframes on Windows and macOS Forever!
import json
import os
import time
import webbrowser
import sys
import re
def handleWindows(extra_seconds):
print("OS : Windows")
@thomasbnt
thomasbnt / code_colors_discordjs.md
Last active May 21, 2024 13:24
Code colors for embed discord.js

Here is an updated list of the colors that are currently implemented with a name. To using colors on discord.js, this is a typedef Colors, Colors.Aqua to get the Aqua color.

Name Int value Hex Code
Default 0 #000000
Aqua 1752220 #1ABC9C
DarkAqua 1146986 #11806A
Green 5763719 #57F287
DarkGreen 2067276 #1F8B4C
@dragonwocky
dragonwocky / discord-webhook.js
Last active May 21, 2024 13:24
js post request example for discord webhooks using the fetch web api
// node.js versions pre-v0.18.0 do not support the fetch api and require a polyfill
// const fetch = require('node-fetch');
fetch(
'https://discordapp.com/api/webhooks/738983040323289120/mzhXrZz0hqOuUaPUjB_RBTE8XJUFLe8fe9mgeJjQCaxjHX14c3SW3ZR199_CDEI-xT56',
{
method: 'post',
headers: {
'Content-Type': 'application/json',
},
body: JSON.stringify({
@voluntas
voluntas / learning-webrtc_2024-02.md
Last active May 21, 2024 13:23
時雨堂 WebRTC 入門 (講師資料) v2024-02

時雨堂 WebRTC 入門 (講師資料) v2024-02

これは時雨堂が 2024 年 2 月 8 日 (木) 14:00-18:00 で開催を予定しているオンラインイベント WebRTC 入門 v2024-02 の 講師用 の資料であり、 参加者用の資料ではありません。

時雨堂 WebRTC 入門 オンラインイベント v2024-02

概要

ChatGPT がある今、学ぼうと思えば好きなだけ学べる時代がきています。

@ThePlenkov
ThePlenkov / boot.sh
Last active May 21, 2024 13:23
Resolve WSL DNS automatically
#!/bin/bash
# Remove existing "nameserver" lines from /etc/resolv.conf
sed -i '/nameserver/d' /etc/resolv.conf
# Run the PowerShell command to generate "nameserver" lines and append to /etc/resolv.conf
# we use full path here to support boot command with root user
/mnt/c/Windows/System32/WindowsPowerShell/v1.0/powershell.exe -Command '(Get-DnsClientServerAddress -AddressFamily IPv4).ServerAddresses | ForEach-Object { "nameserver $_" }' | tr -d '\r'| tee -a /etc/resolv.conf > /dev/null
@mikoim
mikoim / README.md
Last active May 21, 2024 13:21
[Updated! Aug 14 2020] YouTube recommended encoding settings on ffmpeg (+ libx264)

Parameters

Container: MP4

Parameter YouTube recommends setting
-movflags faststart moov atom at the front of the file (Fast Start)

Video codec: H.264

@roachhd
roachhd / README.md
Last active May 21, 2024 13:20
Basics of BrainFuck

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=

BrainFuck Programming Tutorial by: Katie

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=

INTRODUCTION

@utkonos
utkonos / edit_ubuntu_autoinstall.py
Last active May 21, 2024 13:18
Simple Python Script to Edit an Ubuntu ISO to Add Automated Server Install Capability
import io
import pathlib
import pycdlib
ubuntu = pathlib.Path('ubuntu-22.04.1-live-server-amd64.iso')
new_iso_path = pathlib.Path('ubuntu-22.04.1-live-server-amd64-auto.iso')
iso = pycdlib.PyCdlib()
iso.open(ubuntu)
@vuon9
vuon9 / README.md
Last active May 21, 2024 13:16
Powertoys - Keyboard Manager - Common macOS keys mapping

How to install

  • cd C:\Users\${username}\AppData\Local\Microsoft\PowerToys\Keyboard Manager
  • Backup file existing one of default.json
  • Download default.json and add it to the current folder

Mapped keys

key
Esc